package com.ttn.auth.openfeign;


import com.ttn.auth.openfeign.fallback.StudentRecordFeignServiceFallbackFactory;
import com.ttn.common.core.entity.Result;
import com.ttn.common.core.entity.studentrecord.StudentRecord;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient(name = "ttn-student", fallbackFactory = StudentRecordFeignServiceFallbackFactory.class)
public interface StudentRecordFeignService {
    @PostMapping("/student-record/service/query/student-login")
    Result<StudentRecord> serviceQueryStudentLogin(@RequestBody StudentRecord studentRecord);

    @PostMapping("/student-record/service/query/student-record-by-openid/{openid}")
    Result<StudentRecord> queryStudentRecordByOpenId(@PathVariable("openid") String openid);

}
